package com.prp.gwt.client.widgets.register;

import com.google.gwt.event.dom.client.ClickEvent;
import com.google.gwt.event.dom.client.ClickHandler;
import com.google.gwt.user.client.Window;
import com.google.gwt.user.client.ui.HTML;
import com.google.gwt.user.client.ui.Hyperlink;
import com.google.gwt.user.client.ui.VerticalPanel;
import com.prp.gwt.client.Host;

public class RegisterSuccessInfo extends VerticalPanel {
	private static RegisterSuccessInfo instance;

	public static RegisterSuccessInfo getInstance() {
		if (instance == null)
			instance = new RegisterSuccessInfo();
		return instance;
	}

	private RegisterSuccessInfo() {
		setSpacing(20);
		add(new HTML("注册成功<br/>" +
				"系统已发送验证信息到您的邮箱</br>" +
				"查收您的邮件以激活帐户"));
		Hyperlink back = new Hyperlink("返回", "");
		back.addClickHandler(new ClickHandler() {
			@Override
			public void onClick(ClickEvent event) {
				Window.Location.replace(Host.getENTRY());
			}
		});
		add(back);
	}

}
